package file;

import java.io.File;
import java.io.IOException;

/**
 * \* Created with IntelliJ IDEA.
 * \* User: Administrator
 * \* Date: 2022/4/7
 * \* Time: 17:41
 * \* To change this template use File | Settings | File Templates.
 * \* Description:
 * \
 */
public class Demo3 {
    public static void main(String[] args) throws IOException {
        //文件的创建与删除
        File f = new File(".a.test.txt");
        System.out.println(f.exists());//判断是否存在
        System.out.println("创建文件：");
        f.createNewFile();
        System.out.println("创建文件结束");
        System.out.println(f.exists());
    }
}
